package com.hzhjhh.view.manageView.menus;

import java.awt.Color;

import javax.swing.JMenu;
import javax.swing.JMenuItem;

import com.hzhjhh.view.manageView.MainFrame;
import com.hzhjhh.view.manageView.menus.query.QueryMerchandiseInfo;
import com.hzhjhh.view.manageView.menus.query.SaleStatistics;

/**
 * 菜单栏初始化-查询
 * 
 * @author 12083
 *
 */
public class MQuery {

	public static JMenu init(MainFrame mainFrame) {
		JMenu query = new JMenu();
		query.setText("查询");
		query.setBackground(Color.pink);
		
		JMenuItem saleStatisticsMi = new JMenuItem();
		saleStatisticsMi.setText("销售统计");
		saleStatisticsMi.addActionListener(event -> {
			SaleStatistics saleStatistics = new SaleStatistics();
		});
		
		JMenu queryMerchandiseInfo = QueryMerchandiseInfo.init(mainFrame);
		
		query.add(saleStatisticsMi);
		query.add(queryMerchandiseInfo);
		return query;
	}
}
